package com.cait.cait.util;

import com.cait.cait.resultVo.ResultVo;

/**
 * @author ：Yangjiangtao
 * @date ：Created in 2020/2/14 0:27
 * @modified By：Tangjiangtao
 * @description：util for resultvo
 */
public class ResultVoUtil {

    public static ResultVo success(Integer code, String message, Object data){
        ResultVo resultVO = new ResultVo();
        resultVO.setMessage(message);
        resultVO.setCode(code);
        resultVO.setData(data);
        return resultVO;
    }

    public static ResultVo error(Integer code, String message, Object data){
        ResultVo resultVO = new ResultVo();
        resultVO.setMessage(message);
        resultVO.setCode(code);
        resultVO.setData(data);
        return resultVO;
    }

}
